// 获取底部自定义菜单
const app = getApp()
Page({
  data: {
    currentTab: 0,
    prices: [
      { fznumber: '3.1', title: '想法不周全？怎么才能提升思维格局...', name: '上海xxxxxxxxx机构', lable1: '标签1', lable2: '标签2' },
      { fznumber: '3.1', title: '想法不周全？怎么才能提升思维格局...', name: '上海xxxxxxxxx机构', lable1: '标签1', lable2: '标签2'},
      { fznumber: '3.1', title: '想法不周全？怎么才能提升思维格局...', name: '上海xxxxxxxxx机构', lable1: '标签1', lable2: '标签2'},
      { fznumber: '3.1', title: '想法不周全？怎么才能提升思维格局...', name: '上海xxxxxxxxx机构', lable1: '标签1', lable2: '标签2' },
    ],
    activity: [
      { fznumber: '3.1', title: '想法不周全？怎么才能提升思维格局...', name: '上海xxxxxxxxx机构', lable1: '标签1', lable2: '标签2', time: '2018/02/01-2019/06/01', state:'进行中' },
      { fznumber: '3.1', title: '想法不周全？怎么才能提升思维格局...', name: '上海xxxxxxxxx机构', lable1: '标签1', lable2: '标签2', time: '2018/02/01-2019/06/01', state: '进行中' },
      { fznumber: '3.1', title: '想法不周全？怎么才能提升思维格局...', name: '上海xxxxxxxxx机构', lable1: '标签1', lable2: '标签2', time: '2018/02/01-2019/06/01', state: '进行中' },
      { fznumber: '3.1', title: '想法不周全？怎么才能提升思维格局...', name: '上海xxxxxxxxx机构', lable1: '标签1', lable2: '标签2', time: '2018/02/01-2019/06/01', state: '进行中' },
     
    ]
  },

  //滑动切换
  swiperTab: function (e) {
    var that = this;
    that.setData({
      currentTab: e.detail.current
    });
  },
  //点击切换模式
  clickTab: function (e) {
    var that = this;
    if (that.data.currentTab == e.currentTarget.dataset.current) {
      return false;
    } else {
      that.setData({
        currentTab: e.currentTarget.dataset.current
      })
    }
  },
  

  //动态计算高度
  onLoad: function (options) {
    //app.editTabBar();
    var that = this
    wx.getSystemInfo({
      success: function (res) {
        that.setData({
          clientHeight: res.windowHeight
        });
      }
    })

  }
}) 
